package com.tianqi.modules.pms.controller;

import com.tianqi.common.api.CommonResult;
import com.tianqi.modules.pms.dto.request.ShuZiPaiPanReqDTO;
import com.tianqi.modules.pms.dto.request.XkFeiXingReqDTO;
import com.tianqi.modules.pms.dto.response.ShuZiPaiPanRespDTO;
import com.tianqi.modules.pms.dto.response.XkFeiXingRespDTO;
import com.tianqi.modules.pms.service.DaLiuRenService;
import com.tianqi.modules.pms.service.XKFeiXingService;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * @className: XKFeiXingController
 * @description: 玄空飞星控制类
 * @author: zp
 * @create: 2023-08-24 18:31
 **/
@RestController
@RequestMapping("/pms/xuanKongFeiXing")
@Slf4j
public class XKFeiXingController {
    @Autowired
    private XKFeiXingService xKFeiXingService;
    @ApiOperation(value = "获取数字排盘数据")
    @RequestMapping(value = "/getShuZiPaiPan", method = RequestMethod.POST)
    public CommonResult<ShuZiPaiPanRespDTO> getShuZiPaiPan(@RequestBody @Validated ShuZiPaiPanReqDTO shuZiPaiPanReqDTO) {
        return xKFeiXingService.getShuZiPaiPan(shuZiPaiPanReqDTO);
    }

    @ApiOperation(value = "获取玄空飞星排盘数据")
    @RequestMapping(value = "/getXKFeiXing", method = RequestMethod.POST)
    public CommonResult<XkFeiXingRespDTO> getXKFeiXing(@RequestBody @Validated XkFeiXingReqDTO xkFeiXingReqDTO) {
        return xKFeiXingService.getXKFeiXing(xkFeiXingReqDTO);
    }


}
